﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Windows.Forms;

namespace BLL
{
    public class GoogleMapAPI
    {
        public static String URL(String kinhdo, String vido)
        {
            return string.Format("http://maps.googleapis.com/maps/api/staticmap?center={0},{1}&zoom=15&size=80x80&sensor=false&markers=color:blue%7Clabel:A%7C{2},{3}", new object[] { vido, kinhdo, vido, kinhdo });
        }
        public static String URL(String kinhdo, String vido, int dai, int rong)
        {
            return string.Format("http://maps.googleapis.com/maps/api/staticmap?center={0},{1}&zoom=15&size="+dai.ToString()+"x"+rong.ToString()+"&sensor=false&markers=color:blue%7Clabel:A%7C{2},{3}", new object[] { vido, kinhdo, vido, kinhdo });
        }
        public static String URL(String kinhdo, String vido, int dai, int rong,int zoom)
        {
            return string.Format("http://maps.googleapis.com/maps/api/staticmap?center={0},{1}&zoom="+zoom.ToString()+"&size=" + dai.ToString() + "x" + rong.ToString() + "&sensor=false&markers=color:blue%7Clabel:A%7C{2},{3}", new object[] { vido, kinhdo, vido, kinhdo });
        }
        //for win 
        public static void Display(ref WebBrowser web,String URL)
        {
            web.Navigate(URL);
        }
        //for web

       
    }
}
